.TH g_tcaf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5"
.SH NAME
g_tcaf - calculates viscosities of liquids

.B VERSION 4.5
.SH SYNOPSIS
\f3g_tcaf\fP
.BI "\-f" " traj.trr "
.BI "\-s" " topol.tpr "
.BI "\-n" " index.ndx "
.BI "\-ot" " transcur.xvg "
.BI "\-oa" " tcaf_all.xvg "
.BI "\-o" " tcaf.xvg "
.BI "\-of" " tcaf_fit.xvg "
.BI "\-oc" " tcaf_cub.xvg "
.BI "\-ov" " visc_k.xvg "
.BI "\-[no]h" ""
.BI "\-[no]version" ""
.BI "\-nice" " int "
.BI "\-b" " time "
.BI "\-e" " time "
.BI "\-dt" " time "
.BI "\-[no]w" ""
.BI "\-xvg" " enum "
.BI "\-[no]mol" ""
.BI "\-[no]k34" ""
.BI "\-wt" " real "
.BI "\-acflen" " int "
.BI "\-[no]normalize" ""
.BI "\-P" " enum "
.BI "\-fitfn" " enum "
.BI "\-ncskip" " int "
.BI "\-beginfit" " real "
.BI "\-endfit" " real "
.SH DESCRIPTION
\&g_tcaf computes tranverse current autocorrelations.
\&These are used to estimate the shear viscosity eta.
\&For details see: Palmer, JCP 49 (1994) pp 359\-366.


\&Transverse currents are calculated using the
\&k\-vectors (1,0,0) and (2,0,0) each also in the y\- and z\-direction,
\&(1,1,0) and (1,\-1,0) each also in the 2 other planes (these vectors
\&are not independent) and (1,1,1) and the 3 other box diagonals (also
\&not independent). For each k\-vector the sine and cosine are used, in
\&combination with the velocity in 2 perpendicular directions. This gives
\&a total of 16*2*2=64 transverse currents. One autocorrelation is
\&calculated fitted for each k\-vector, which gives 16 tcaf's. Each of
\&these tcaf's is fitted to f(t) = exp(\-v)(cosh(Wv) + 1/W sinh(Wv)),
\&v = \-t/(2 tau), W = sqrt(1 \- 4 tau eta/rho k2), which gives 16 tau's
\&and eta's. The fit weights decay with time as exp(\-t/wt), the tcaf and
\&fit are calculated up to time 5*wt.
\&The eta's should be fitted to 1 \- a eta(k) k2, from which
\&one can estimate the shear viscosity at k=0.


\&When the box is cubic, one can use the option \fB \-oc\fR, which
\&averages the tcaf's over all k\-vectors with the same length.
\&This results in more accurate tcaf's.
\&Both the cubic tcaf's and fits are written to \fB \-oc\fR
\&The cubic eta estimates are also written to \fB \-ov\fR.


\&With option \fB \-mol\fR the transverse current is determined of
\&molecules instead of atoms. In this case the index group should
\&consist of molecule numbers instead of atom numbers.


\&The k\-dependent viscosities in the \fB \-ov\fR file should be
\&fitted to eta(k) = eta0 (1 \- a k2) to obtain the viscosity at
\&infinite wavelength.


\&NOTE: make sure you write coordinates and velocities often enough.
\&The initial, non\-exponential, part of the autocorrelation function
\&is very important for obtaining a good fit.
.SH FILES
.BI "\-f" " traj.trr" 
.B Input
 Full precision trajectory: trr trj cpt 

.BI "\-s" " topol.tpr" 
.B Input, Opt.
 Structure+mass(db): tpr tpb tpa gro g96 pdb 

.BI "\-n" " index.ndx" 
.B Input, Opt.
 Index file 

.BI "\-ot" " transcur.xvg" 
.B Output, Opt.
 xvgr/xmgr file 

.BI "\-oa" " tcaf_all.xvg" 
.B Output
 xvgr/xmgr file 

.BI "\-o" " tcaf.xvg" 
.B Output
 xvgr/xmgr file 

.BI "\-of" " tcaf_fit.xvg" 
.B Output
 xvgr/xmgr file 

.BI "\-oc" " tcaf_cub.xvg" 
.B Output, Opt.
 xvgr/xmgr file 

.BI "\-ov" " visc_k.xvg" 
.B Output
 xvgr/xmgr file 

.SH OTHER OPTIONS
.BI "\-[no]h"  "no    "
 Print help info and quit

.BI "\-[no]version"  "no    "
 Print version info and quit

.BI "\-nice"  " int" " 19" 
 Set the nicelevel

.BI "\-b"  " time" " 0     " 
 First frame (ps) to read from trajectory

.BI "\-e"  " time" " 0     " 
 Last frame (ps) to read from trajectory

.BI "\-dt"  " time" " 0     " 
 Only use frame when t MOD dt = first time (ps)

.BI "\-[no]w"  "no    "
 View output xvg, xpm, eps and pdb files

.BI "\-xvg"  " enum" " xmgrace" 
 xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR

.BI "\-[no]mol"  "no    "
 Calculate tcaf of molecules

.BI "\-[no]k34"  "no    "
 Also use k=(3,0,0) and k=(4,0,0)

.BI "\-wt"  " real" " 5     " 
 Exponential decay time for the TCAF fit weights

.BI "\-acflen"  " int" " \-1" 
 Length of the ACF, default is half the number of frames

.BI "\-[no]normalize"  "yes   "
 Normalize ACF

.BI "\-P"  " enum" " 0" 
 Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR

.BI "\-fitfn"  " enum" " none" 
 Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR

.BI "\-ncskip"  " int" " 0" 
 Skip N points in the output file of correlation functions

.BI "\-beginfit"  " real" " 0     " 
 Time where to begin the exponential fit of the correlation function

.BI "\-endfit"  " real" " \-1    " 
 Time where to end the exponential fit of the correlation function, \-1 is until the end

.SH SEE ALSO
.BR gromacs(7)

More information about \fBGROMACS\fR is available at <\fIhttp://www.gromacs.org/\fR>.
